#!/bin/bash
#leao:Thu Aug 22 05:07:58 PM CST 2024
path=$1

if [ -x "$path" ];then
    `ps -a | grep -q $path`;
    ret=$?
    if [ $ret = 0 ];then
        echo "${path} was running"
    else
        echo "${path} is running"
        ./$path
    fi
else
    echo "文件不可执行"
fi